package com.sgb.kjwl.model.entity.transport;

import android.os.Parcel;
import android.os.Parcelable;
import android.text.TextUtils;

import com.sgb.kjwl.model.entity.CarInfo;
import com.sgb.kjwl.model.entity.self.AddField;
import com.sgb.kjwl.utils.NumberUtil;

import java.io.Serializable;
import java.util.List;

/**
 * Time:2021/3/11
 * Author:黄淋
 * Description:运输订单详情
 */
public class TransportOrderEntity implements Parcelable {
    // @ApiModelProperty("货源no")
    public String goodsSourceNo;
    // @ApiModelProperty("货源 货物类型")
    public String goodsModeName;
    // @ApiModelProperty("货源 运费单价")
    public String freight;
    // @ApiModelProperty("货源 运费单位")
    public int freightUnit;
    // @ApiModelProperty("货源 重量")
    public String weight;
    // @ApiModelProperty("货源 体积")
    public String volume;
    // @ApiModelProperty("货源 装卸方式")
    public String handleTypeName;
    public String handleTypeNo;
    // @ApiModelProperty("企业 || 团队 名称")
    public String companyName;
    // @ApiModelProperty("1：企业发布 / 2：团队发布")
    private int terminal;
    // @ApiModelProperty("货源  装车要求： 1运方装车 ，2业主装车，3商议")
    public Integer loadRequire;
    // @ApiModelProperty("货源 卸车要求：1运方卸车，2业主卸车，3商议")
    public Integer unloadRequire;
    // @ApiModelProperty("货源 到货时间")
    public int arrivalTime;
    // @ApiModelProperty("货源 货物损坏或丢失赔偿约定")
    public String lostPromise;
    // @ApiModelProperty("货源 履约保证金")
    public String performanceBond;
    // @ApiModelProperty("货源 逾期装货或送货违约责任约定")
    public String overduePromise;
    // @ApiModelProperty("货源 其他约定")
    public String otherPromise;
    // @ApiModelProperty("货源 发货单位")
    public String sendGoodsUnit;
    // @ApiModelProperty("货源 发货人")
    public String sendPeople;
    // @ApiModelProperty("货源 发货人电话")
    public String sendPhone;
    // @ApiModelProperty("货源 收货单位")
    public String receiveGoodsUnit;
    // @ApiModelProperty("货源 收货人")
    public String receptionPeople;
    // @ApiModelProperty("货源 收货人电话")
    public String receptionPhone;
    // @ApiModelProperty("货源 支付方式")
    public String payType;
    // @ApiModelProperty("货源 收款账户要求")
    public String receiptAccountRequire;
    /**
     * 开票信息相关
     */
    // @ApiModelProperty("货源 发票要求")
    public String invoice;
    // @ApiModelProperty("货源 税率")
    public String tariff;
    // @ApiModelProperty("货源 其他付款要求")
    public String otherPaymentRequire;

    //发票信息Id
    public String quoteInvoiceInfoId;
    // @ApiModelProperty("货源 开票公司名称")
    public String quoteshCompanyName;
    // @ApiModelProperty("货源 开票税号")
    public String quoteCreditCode;
    // @ApiModelProperty("货源 开票地址")
    public String quoteAddress;
    // @ApiModelProperty("货源 开票企业电话")
    public String quotePhone;
    // @ApiModelProperty("货源 开票开户银行")
    public String quoteBank;
    // @ApiModelProperty("货源 开票银行账户")
    public String quoteBankAccount;
    // @ApiModelProperty("货源 开票开户行号")
    public String quoteBankNumber;
    // @ApiModelProperty("订单 下单时间")
    public Long createTime;
    public Long paymentEndTime;//支付信息费的最后时间
    public Long systemTime;//系统当前时间
    // @ApiModelProperty("订单 订单号")
    public String orderNo;
    // @ApiModelProperty("订单 实际信息费")
    public String mMessagePrice;
    // @ApiModelProperty("订单 信息费流水号")
    public String messageSerialNumber;
    // @ApiModelProperty("订单 信息费支付时间")
    public Long messagePayTime;
    // @ApiModelProperty("订单 信息费手续费")
    public String messageCharge;
    // @ApiModelProperty("订单 信息费支付方式")
    public String messagePayWay;
    // @ApiModelProperty("订单 实际运费")
    public String freightPrice;
    // @ApiModelProperty("订单 运费流水号")
    public String freightSerialNumber;
    // @ApiModelProperty("订单 运费支付时间")
    public Long freightPayTime;
    // @ApiModelProperty("订单 运费手续费")
    public String freightCharge;
    // @ApiModelProperty("订单 运费支付方式")
    public String freightPayWay;
    //   // @ApiModelProperty("订单 订单状态 0待司机付款 1待货主确认  2待司机发车 3运输中 4已完成 5已取消 6待货主支付")
    public Integer status;
    // @ApiModelProperty("订单 待发车时间")
    public Long startTime;
    public Long transitTime;//发车时间
    // @ApiModelProperty("订单 司机发车凭证图片")
    public String departureImg;
    // @ApiModelProperty("订单 已完成时间")
    public Long completeTime;
    // @ApiModelProperty("订单 货主收货凭证图片")
    public String receiveImg;
    // @ApiModelProperty("承运 司机认证的userNo")
    public String driverUserNo;
    // @ApiModelProperty("司机姓名")
    public String userName;
    // @ApiModelProperty("司机电话")
    public String telPhone;
    // @ApiModelProperty("司机年龄")
    public String carAge;
    // @ApiModelProperty("司机驾龄")
    public String driverAge;
    // @ApiModelProperty("承运 车牌号")
    public String carNumber;
    // @ApiModelProperty("承运 车型")
    public String carTypeName;
    // @ApiModelProperty("承运 车长")
    public String carLenName;
    // @ApiModelProperty("承运 重量")
    public String carWeight;
    // @ApiModelProperty("承运 栏高")
    public String heightHurdle;
    // @ApiModelProperty("承运 车辆功能")
    public String functionNos;
    // @ApiModelProperty("实际下单 信息费")
    public String messagePrice;
    // @ApiModelProperty("实际下单 运费总结")
    public String allFreight;
    // @ApiModelProperty("司机当前 纬度")
    public float latitude;
    // @ApiModelProperty("司机当前 经度")
    public float longitude;
    // @ApiModelProperty("实际下单 装车时间")
    public Long shipmentTime;
    // @ApiModelProperty("实际下单 装车结束时间")
    public Long shipmentEndTime;
    // @ApiModelProperty("装卸地实体")
    public OperateGoodsSourcePlaceVO place;
    //    @ApiModelProperty("货主电话")
    private String goodsOwnerPhone;
    //    @ApiModelProperty("司机当前省")
    private String provinceName;
    //    @ApiModelProperty("司机当前市")
    private String cityName;
    //    @ApiModelProperty("司机当前区")
    private String districtName;
    //    @ApiModelProperty("司机当前详细地址")
    private String detailAddress;

    /**
     * 目的地城市名称
     */
    private String destCityName;
    /**
     * 目的地区名称
     */
    private String destDistrictName;

    /**
     * logo
     */
    private String logo;

    /**
     * 车主头像
     */

    private String driverHeadImg;

    /**
     * 货主userNo
     **/
    private String sourceUserNo;
    /**
     * 货主的ImAccount账号
     **/
    private String goodsOwnerImAccount;
    /**
     * 车主的ImAccount账号
     **/
    private String driverOwnerImAccount;

    /**
     * 订单轨迹
     */
    private List<DriverLocationVo> locationList;

    /**
     * 装车开始时间点
     * 25——表示全天
     */
    private int startPointTime;

    /**
     * 装车结束时间点
     * 25——表示全天
     */
    private int endPointTime;

    /**
     * 运费选项 0一口价 1电议
     */
    private String freightType;

    /**
     * 运输方式 0 零担 1 整车
     */
    private Integer transportType;

    /**
     * v2.0.7 1线上支付，0线下支付
     */
    private Integer isOnlinePayment;
    /**
     * v2.0.7 线下收款凭证 多个图片地址用英文逗号隔开
     */
    public String offlineImg;
    private String secondGoodsTypeName;//2.1.4 新增 二级货物类型

    private List<CarInfo> driverAuths;
    private Integer quoteOfferType;//承运类型 1 企业 2 团队 3 个人
    private Long inTime;//预计到场时间

    private String quoteCompanyName;
    private String quoteTeamName;
    private String contrcts;//承运方联系人
    private String contrctsNumber;//承运方联系电话（团队/企业取这个）
    private String note;//备注
    private List<AddField> addField;

    /**
     * 信息费联动订单编号
     */
    private String messageOrderNo;

    protected TransportOrderEntity(Parcel in) {
        goodsSourceNo = in.readString();
        goodsModeName = in.readString();
        freight = in.readString();
        freightUnit = in.readInt();
        weight = in.readString();
        volume = in.readString();
        handleTypeName = in.readString();
        handleTypeNo = in.readString();
        companyName = in.readString();
        terminal = in.readInt();
        if (in.readByte() == 0) {
            loadRequire = null;
        } else {
            loadRequire = in.readInt();
        }
        if (in.readByte() == 0) {
            unloadRequire = null;
        } else {
            unloadRequire = in.readInt();
        }
        arrivalTime = in.readInt();
        lostPromise = in.readString();
        performanceBond = in.readString();
        overduePromise = in.readString();
        otherPromise = in.readString();
        sendGoodsUnit = in.readString();
        sendPeople = in.readString();
        sendPhone = in.readString();
        receiveGoodsUnit = in.readString();
        receptionPeople = in.readString();
        receptionPhone = in.readString();
        payType = in.readString();
        receiptAccountRequire = in.readString();
        invoice = in.readString();
        tariff = in.readString();
        otherPaymentRequire = in.readString();
        quoteInvoiceInfoId = in.readString();
        quoteshCompanyName = in.readString();
        quoteCreditCode = in.readString();
        quoteAddress = in.readString();
        quotePhone = in.readString();
        quoteBank = in.readString();
        quoteBankAccount = in.readString();
        quoteBankNumber = in.readString();
        if (in.readByte() == 0) {
            createTime = null;
        } else {
            createTime = in.readLong();
        }
        if (in.readByte() == 0) {
            paymentEndTime = null;
        } else {
            paymentEndTime = in.readLong();
        }
        if (in.readByte() == 0) {
            systemTime = null;
        } else {
            systemTime = in.readLong();
        }
        orderNo = in.readString();
        mMessagePrice = in.readString();
        messageSerialNumber = in.readString();
        if (in.readByte() == 0) {
            messagePayTime = null;
        } else {
            messagePayTime = in.readLong();
        }
        messageCharge = in.readString();
        messagePayWay = in.readString();
        freightPrice = in.readString();
        freightSerialNumber = in.readString();
        if (in.readByte() == 0) {
            freightPayTime = null;
        } else {
            freightPayTime = in.readLong();
        }
        freightCharge = in.readString();
        freightPayWay = in.readString();
        if (in.readByte() == 0) {
            status = null;
        } else {
            status = in.readInt();
        }
        if (in.readByte() == 0) {
            startTime = null;
        } else {
            startTime = in.readLong();
        }
        if (in.readByte() == 0) {
            transitTime = null;
        } else {
            transitTime = in.readLong();
        }
        departureImg = in.readString();
        if (in.readByte() == 0) {
            completeTime = null;
        } else {
            completeTime = in.readLong();
        }
        receiveImg = in.readString();
        driverUserNo = in.readString();
        userName = in.readString();
        telPhone = in.readString();
        carAge = in.readString();
        driverAge = in.readString();
        carNumber = in.readString();
        carTypeName = in.readString();
        carLenName = in.readString();
        carWeight = in.readString();
        heightHurdle = in.readString();
        functionNos = in.readString();
        messagePrice = in.readString();
        allFreight = in.readString();
        latitude = in.readFloat();
        longitude = in.readFloat();
        if (in.readByte() == 0) {
            shipmentTime = null;
        } else {
            shipmentTime = in.readLong();
        }
        if (in.readByte() == 0) {
            shipmentEndTime = null;
        } else {
            shipmentEndTime = in.readLong();
        }
        goodsOwnerPhone = in.readString();
        provinceName = in.readString();
        cityName = in.readString();
        districtName = in.readString();
        detailAddress = in.readString();
        destCityName = in.readString();
        destDistrictName = in.readString();
        logo = in.readString();
        driverHeadImg = in.readString();
        sourceUserNo = in.readString();
        goodsOwnerImAccount = in.readString();
        driverOwnerImAccount = in.readString();
        startPointTime = in.readInt();
        endPointTime = in.readInt();
        freightType = in.readString();
        if (in.readByte() == 0) {
            transportType = null;
        } else {
            transportType = in.readInt();
        }
        if (in.readByte() == 0) {
            isOnlinePayment = null;
        } else {
            isOnlinePayment = in.readInt();
        }
        offlineImg = in.readString();
        secondGoodsTypeName = in.readString();
        if (in.readByte() == 0) {
            quoteOfferType = null;
        } else {
            quoteOfferType = in.readInt();
        }
        if (in.readByte() == 0) {
            inTime = null;
        } else {
            inTime = in.readLong();
        }
        quoteCompanyName = in.readString();
        quoteTeamName = in.readString();
        contrcts = in.readString();
        contrctsNumber = in.readString();
        note = in.readString();
        addField = in.createTypedArrayList(AddField.CREATOR);
        messageOrderNo = in.readString();
    }

    public static final Creator<TransportOrderEntity> CREATOR = new Creator<TransportOrderEntity>() {
        @Override
        public TransportOrderEntity createFromParcel(Parcel in) {
            return new TransportOrderEntity(in);
        }

        @Override
        public TransportOrderEntity[] newArray(int size) {
            return new TransportOrderEntity[size];
        }
    };

    public String getMessageOrderNo() {
        return messageOrderNo;
    }

    public List<AddField> getAddField() {
        return addField;
    }

    public String getNote() {
        return note;
    }

    public String getContrcts() {
        return contrcts;
    }

    public String getContrctsNumber() {
        return contrctsNumber;
    }

    public String getQuoteCompanyName() {
        return quoteCompanyName;
    }

    public String getQuoteTeamName() {
        return quoteTeamName;
    }

    public String getCarrierGroupName() {

        if (!TextUtils.isEmpty(quoteCompanyName)) {
            return quoteCompanyName;
        }

        if (!TextUtils.isEmpty(quoteTeamName)) {
            return quoteTeamName;
        }

        return "";
    }

    public Long getInTime() {
        return inTime;
    }

    public void setInTime(Long inTime) {
        this.inTime = inTime;
    }

    public Integer getQuoteOfferType() {
        return quoteOfferType;
    }

    public void setQuoteOfferType(Integer quoteOfferType) {
        this.quoteOfferType = quoteOfferType;
    }

    public List<CarInfo> getDriverAuths() {
        return driverAuths;
    }

    public void setDriverAuths(List<CarInfo> driverAuths) {
        this.driverAuths = driverAuths;
    }

    public Integer getIsOnlinePayment() {
        if (isOnlinePayment == null) {
            return 1;
        }
        return isOnlinePayment;
    }

    public void setIsOnlinePayment(Integer isOnlinePayment) {
        this.isOnlinePayment = isOnlinePayment;
    }

    public int getStartPointTime() {
        return startPointTime;
    }

    public void setStartPointTime(int startPointTime) {
        this.startPointTime = startPointTime;
    }

    public int getEndPointTime() {
        return endPointTime;
    }

    public void setEndPointTime(int endPointTime) {
        this.endPointTime = endPointTime;
    }

    public String getFreightType() {
        return freightType;
    }

    public void setFreightType(String freightType) {
        this.freightType = freightType;
    }

    public Integer getTransportType() {
        return transportType;
    }

    public void setTransportType(Integer transportType) {
        this.transportType = transportType;
    }

    public List<DriverLocationVo> getLocationList() {
        return locationList;
    }

    public void setLocationList(List<DriverLocationVo> locationList) {
        this.locationList = locationList;
    }

    public String getDestCityName() {
        return destCityName == null ? "" : destCityName;
    }

    public void setDestCityName(String destCityName) {
        this.destCityName = destCityName;
    }

    public String getDestDistrictName() {
        return destDistrictName == null ? "" : destDistrictName;
    }

    public void setDestDistrictName(String destDistrictName) {
        this.destDistrictName = destDistrictName;
    }

    public String getOfflineImg() {
        return offlineImg;
    }

    public void setOfflineImg(String offlineImg) {
        this.offlineImg = offlineImg;
    }

    public Long getTransitTime() {
        return transitTime;
    }

    public void setTransitTime(Long transitTime) {
        this.transitTime = transitTime;
    }

    public String getGoodsSourceNo() {
        return goodsSourceNo == null ? "" : goodsSourceNo;
    }

    public void setGoodsSourceNo(String goodsSourceNo) {
        this.goodsSourceNo = goodsSourceNo;
    }

    public String getGoodsModeName() {
        return goodsModeName == null ? "" : goodsModeName;
    }

    public void setGoodsModeName(String goodsModeName) {
        this.goodsModeName = goodsModeName;
    }

    public String getFreight() {
        return freight == null ? "" : NumberUtil.trim0(freight);
    }

    public void setFreight(String freight) {
        this.freight = freight;
    }

    public int getFreightUnit() {
        return freightUnit;
    }

    public void setFreightUnit(int freightUnit) {
        this.freightUnit = freightUnit;
    }

    public String getWeight() {
        return weight == null ? "" : NumberUtil.trim0(weight);
    }

    public void setWeight(String weight) {
        this.weight = weight;
    }

    public String getVolume() {
        return volume == null ? "" : NumberUtil.trim0(volume);
    }

    public void setVolume(String volume) {
        this.volume = volume;
    }

    public String getHandleTypeName() {
        return handleTypeName == null ? "" : handleTypeName;
    }

    public void setHandleTypeName(String handleTypeName) {
        this.handleTypeName = handleTypeName;
    }

    public String getHandleTypeNo() {
        return handleTypeNo;
    }

    public void setHandleTypeNo(String handleTypeNo) {
        this.handleTypeNo = handleTypeNo;
    }

    public String getCompanyName() {
        return companyName == null || companyName.isEmpty() ? "/" : companyName;
    }

    public void setCompanyName(String companyName) {
        this.companyName = companyName;
    }

    public int getLoadRequire() {
        return loadRequire;
    }

    public void setLoadRequire(int loadRequire) {
        this.loadRequire = loadRequire;
    }

    public int getUnloadRequire() {
        return unloadRequire;
    }

    public void setUnloadRequire(int unloadRequire) {
        this.unloadRequire = unloadRequire;
    }

    public int getArrivalTime() {
        return arrivalTime;
    }

    public void setArrivalTime(int arrivalTime) {
        this.arrivalTime = arrivalTime;
    }

    public String getLostPromise() {
        return lostPromise == null ? "" : lostPromise;
    }

    public void setLostPromise(String lostPromise) {
        this.lostPromise = lostPromise;
    }

    public String getPerformanceBond() {
        return performanceBond == null ? "" : performanceBond;
    }

    public void setPerformanceBond(String performanceBond) {
        this.performanceBond = performanceBond;
    }

    public String getOverduePromise() {
        return overduePromise == null ? "" : overduePromise;
    }

    public void setOverduePromise(String overduePromise) {
        this.overduePromise = overduePromise;
    }

    public String getOtherPromise() {
        return otherPromise == null ? "" : otherPromise;
    }

    public void setOtherPromise(String otherPromise) {
        this.otherPromise = otherPromise;
    }

    public String getSendGoodsUnit() {
        return sendGoodsUnit == null || sendGoodsUnit.isEmpty() ? "/" : sendGoodsUnit;
    }

    public void setSendGoodsUnit(String sendGoodsUnit) {
        this.sendGoodsUnit = sendGoodsUnit;
    }

    public String getSendPeople() {
        return sendPeople == null || sendPeople.isEmpty() ? "/" : sendPeople;
    }

    public void setSendPeople(String sendPeople) {
        this.sendPeople = sendPeople;
    }

    public String getSendPhone() {
        return sendPhone == null || sendPhone.isEmpty() ? "/" : sendPhone;
    }

    public void setSendPhone(String sendPhone) {
        this.sendPhone = sendPhone;
    }

    public String getReceiveGoodsUnit() {
        return receiveGoodsUnit == null || receiveGoodsUnit.isEmpty() ? "/" : receiveGoodsUnit;
    }

    public void setReceiveGoodsUnit(String receiveGoodsUnit) {
        this.receiveGoodsUnit = receiveGoodsUnit;
    }

    public String getReceptionPeople() {
        return receptionPeople == null || receptionPeople.isEmpty() ? "/" : receptionPeople;
    }

    public void setReceptionPeople(String receptionPeople) {
        this.receptionPeople = receptionPeople;
    }

    public String getReceptionPhone() {
        return receptionPhone == null || receptionPhone.isEmpty() ? "/" : receptionPhone;
    }

    public void setReceptionPhone(String receptionPhone) {
        this.receptionPhone = receptionPhone;
    }

    public String getPayType() {
        return payType == null || payType.isEmpty() ? "/" : payType;
    }

    public void setPayType(String payType) {
        this.payType = payType;
    }

    public String getReceiptAccountRequire() {
        return receiptAccountRequire == null || receiptAccountRequire.isEmpty() ? "/" : receiptAccountRequire;
    }

    public void setReceiptAccountRequire(String receiptAccountRequire) {
        this.receiptAccountRequire = receiptAccountRequire;
    }

    public String getInvoice() {
        return invoice == null ? "" : invoice;
    }

    public void setInvoice(String invoice) {
        this.invoice = invoice;
    }

    public String getTariff() {
        return tariff == null ? "" : tariff;
    }

    public void setTariff(String tariff) {
        this.tariff = tariff;
    }

    public String getOtherPaymentRequire() {
        return otherPaymentRequire == null ? "" : otherPaymentRequire;
    }

    public void setOtherPaymentRequire(String otherPaymentRequire) {
        this.otherPaymentRequire = otherPaymentRequire;
    }

    public String getInvoicingCompanyName() {
        return quoteshCompanyName == null ? "" : quoteshCompanyName;
    }

    public String getInvoicingTaxNumber() {
        return quoteCreditCode == null ? "" : quoteCreditCode;
    }

    public String getInvoicingAddress() {
        return quoteAddress == null ? "" : quoteAddress;
    }

    public String getInvoicingCompanyPhone() {
        return quotePhone == null ? "" : quotePhone;
    }

    public String getInvoicingBank() {
        return quoteBank == null ? "" : quoteBank;
    }

    public String getInvoicingBankAccount() {
        return quoteBankAccount == null ? "" : quoteBankAccount;
    }

    public String getInvoicingBankNumber() {
        return quoteBankNumber == null ? "" : quoteBankNumber;
    }

    public String getQuoteInvoiceInfoId() {
        return quoteInvoiceInfoId;
    }

    public boolean isNeedShowInvoiceInfo() {
        if (TextUtils.isEmpty(quoteInvoiceInfoId)) {
            return false;
        }
        if (TextUtils.isEmpty(quoteshCompanyName) && TextUtils.isEmpty(quotePhone) && TextUtils.isEmpty(quoteAddress)
                && TextUtils.isEmpty(quoteBank) && TextUtils.isEmpty(quoteBankAccount) && TextUtils.isEmpty(quoteBankNumber)
                && TextUtils.isEmpty(quoteCreditCode)) {
            return false;
        } else
            return true;
    }

    public Long getCreateTime() {
        return createTime;
    }

    public Long getPaymentEndTime() {
        return paymentEndTime;
    }

    public Long getSystemTime() {
        return systemTime;
    }

    public String getOrderNo() {
        return orderNo;
    }

    public void setOrderNo(String orderNo) {
        this.orderNo = orderNo;
    }

    public String getmMessagePrice() {
        return NumberUtil.trim0(mMessagePrice);
    }

    public void setmMessagePrice(String mMessagePrice) {
        this.mMessagePrice = mMessagePrice;
    }

    public String getMessageSerialNumber() {
        return messageSerialNumber;
    }

    public void setMessageSerialNumber(String messageSerialNumber) {
        this.messageSerialNumber = messageSerialNumber;
    }

    public Long getMessagePayTime() {
        return messagePayTime;
    }

    public void setMessagePayTime(Long messagePayTime) {
        this.messagePayTime = messagePayTime;
    }

    public String getMessageCharge() {
        return messageCharge;
    }

    public void setMessageCharge(String messageCharge) {
        this.messageCharge = messageCharge;
    }

    public String getMessagePayWay() {
        return messagePayWay;
    }

    public void setMessagePayWay(String messagePayWay) {
        this.messagePayWay = messagePayWay;
    }

    public String getFreightPrice() {
        return freightPrice;
    }

    public void setFreightPrice(String freightPrice) {
        this.freightPrice = freightPrice;
    }

    public String getFreightSerialNumber() {
        return freightSerialNumber;
    }

    public void setFreightSerialNumber(String freightSerialNumber) {
        this.freightSerialNumber = freightSerialNumber;
    }

    public Long getFreightPayTime() {
        return freightPayTime;
    }

    public void setFreightPayTime(Long freightPayTime) {
        this.freightPayTime = freightPayTime;
    }

    public String getFreightCharge() {
        return freightCharge;
    }

    public void setFreightCharge(String freightCharge) {
        this.freightCharge = freightCharge;
    }

    public String getFreightPayWay() {
        return freightPayWay;
    }

    public void setFreightPayWay(String freightPayWay) {
        this.freightPayWay = freightPayWay;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public Long getStartTime() {
        return startTime;
    }

    public void setStartTime(Long startTime) {
        this.startTime = startTime;
    }

    public String getDepartureImg() {
        return departureImg == null ? "" : departureImg;
    }

    public void setDepartureImg(String departureImg) {
        this.departureImg = departureImg;
    }

    public Long getCompleteTime() {
        return completeTime;
    }

    public void setCompleteTime(Long completeTime) {
        this.completeTime = completeTime;
    }

    public String getReceiveImg() {
        return receiveImg == null ? "" : receiveImg;
    }

    public void setReceiveImg(String receiveImg) {
        this.receiveImg = receiveImg;
    }

    public String getDriverUserNo() {
        return driverUserNo == null ? "" : driverUserNo;
    }

    public void setDriverUserNo(String driverUserNo) {
        this.driverUserNo = driverUserNo;
    }

    public String getUserName() {
        return userName == null || userName.isEmpty() ? "/" : userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getTelPhone() {
        return telPhone == null || telPhone.isEmpty() ? "/" : telPhone;
    }

    public String getTelPhoneNum() {
        return telPhone;
    }

    public void setTelPhone(String telPhone) {
        this.telPhone = telPhone;
    }

    public String getCarAge() {
        return carAge == null || carAge.isEmpty() ? "/" : carAge;
    }

    public void setCarAge(String carAge) {
        this.carAge = carAge;
    }

    public String getDriverAge() {
        return driverAge == null || driverAge.isEmpty() ? "/" : driverAge;
    }

    public void setDriverAge(String driverAge) {
        this.driverAge = driverAge;
    }

    public String getCarNumber() {
        return carNumber == null ? "" : carNumber;
    }

    public void setCarNumber(String carNumber) {
        this.carNumber = carNumber;
    }

    public String getCarTypeName() {
        return carTypeName == null ? "" : carTypeName;
    }

    public void setCarTypeName(String carTypeName) {
        this.carTypeName = carTypeName;
    }

    public String getCarLenName() {
        return carLenName == null ? "" : carLenName;
    }

    public void setCarLenName(String carLenName) {
        this.carLenName = carLenName;
    }

    public String getCarWeight() {
        return carWeight == null ? "" : NumberUtil.trim0(carWeight);
    }

    public void setCarWeight(String carWeight) {
        this.carWeight = carWeight;
    }

    public String getHeightHurdle() {
        return heightHurdle == null ? "" : NumberUtil.trim0(heightHurdle);
    }

    public void setHeightHurdle(String heightHurdle) {
        this.heightHurdle = heightHurdle;
    }

    public String getFunctionNos() {
        return functionNos == null ? "" : functionNos;
    }

    public void setFunctionNos(String functionNos) {
        this.functionNos = functionNos;
    }

    public String getMessagePrice() {
        if (messagePrice == null || messagePrice.isEmpty()) {
            return "0元";
        }
        return NumberUtil.trim0(messagePrice) + "元";
    }

    public void setMessagePrice(String messagePrice) {
        this.messagePrice = messagePrice;
    }

    public String getAllFreight() {
        if (allFreight == null || allFreight.isEmpty()) {
            return "0";
        }
        return NumberUtil.trim0(allFreight);
    }

    public void setAllFreight(String allFreight) {
        this.allFreight = allFreight;
    }

    public float getLatitude() {
        return latitude;
    }

    public void setLatitude(float latitude) {
        this.latitude = latitude;
    }

    public float getLongitude() {
        return longitude;
    }

    public void setLongitude(float longitude) {
        this.longitude = longitude;
    }

    public Long getShipmentTime() {
        return shipmentTime == null ? 0 : shipmentTime;
    }

    public void setShipmentTime(Long shipmentTime) {
        this.shipmentTime = shipmentTime;
    }

    public Long getShipmentEndTime() {
        return shipmentEndTime == null ? 0 : shipmentEndTime;
    }

    public void setShipmentEndTime(Long shipmentEndTime) {
        this.shipmentEndTime = shipmentEndTime;
    }

    public int getTerminal() {
        return terminal;
    }

    public void setTerminal(int terminal) {
        this.terminal = terminal;
    }

    public OperateGoodsSourcePlaceVO getPlace() {
        return place;
    }

    public void setPlace(OperateGoodsSourcePlaceVO place) {
        this.place = place;
    }

    public String getloadRequireWords() {
        if (loadRequire == null)
            return "";
        switch (loadRequire) {
            case 1:
                return "运方装车";
            case 2:
                return "业主装车";
            case 3:
                return "商议";
            default:
                return "/";
        }
    }

    public String getUnloadRequireWords() {
        if (unloadRequire == null)
            return "";
        switch (unloadRequire) {
            case 1:
                return "运方装车";
            case 2:
                return "业主装车";
            case 3:
                return "商议";
            default:
                return "/";
        }
    }

    public String getSourceUserNo() {
        return sourceUserNo == null ? "" : sourceUserNo;
    }

    public void setSourceUserNo(String sourceUserNo) {
        this.sourceUserNo = sourceUserNo;
    }

    public String getGoodsOwnerImAccount() {
        return goodsOwnerImAccount == null ? "" : goodsOwnerImAccount;
    }

    public void setGoodsOwnerImAccount(String goodsOwnerImAccount) {
        this.goodsOwnerImAccount = goodsOwnerImAccount;
    }

    public String getDriverOwnerImAccount() {
        return driverOwnerImAccount == null ? "" : driverOwnerImAccount;
    }

    public void setDriverOwnerImAccount(String driverOwnerImAccount) {
        this.driverOwnerImAccount = driverOwnerImAccount;
    }

    public String getGoodsOwnerPhone() {
        return goodsOwnerPhone;
    }

    public void setGoodsOwnerPhone(String goodsOwnerPhone) {
        this.goodsOwnerPhone = goodsOwnerPhone;
    }

    public String getProvinceName() {
        return provinceName == null ? "" : provinceName;
    }

    public void setProvinceName(String provinceName) {
        this.provinceName = provinceName;
    }

    public String getCityName() {
        return cityName == null ? "" : cityName;
    }

    public void setCityName(String cityName) {
        this.cityName = cityName;
    }

    public String getDistrictName() {
        return districtName == null ? "" : districtName;
    }

    public void setDistrictName(String districtName) {
        this.districtName = districtName;
    }

    public String getDetailAddress() {
        return detailAddress == null ? "" : detailAddress;
    }

    public void setDetailAddress(String detailAddress) {
        this.detailAddress = detailAddress;
    }

    public String getLogo() {
        return logo;
    }

    public void setLogo(String logo) {
        this.logo = logo;
    }

    public String getDriverHeadImg() {
        return driverHeadImg;
    }

    public void setDriverHeadImg(String driverHeadImg) {
        this.driverHeadImg = driverHeadImg;
    }

    public String getSecondGoodsTypeName() {
        return secondGoodsTypeName;
    }

    public void setSecondGoodsTypeName(String secondGoodsTypeName) {
        this.secondGoodsTypeName = secondGoodsTypeName;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeString(goodsSourceNo);
        dest.writeString(goodsModeName);
        dest.writeString(freight);
        dest.writeInt(freightUnit);
        dest.writeString(weight);
        dest.writeString(volume);
        dest.writeString(handleTypeName);
        dest.writeString(handleTypeNo);
        dest.writeString(companyName);
        dest.writeInt(terminal);
        if (loadRequire == null) {
            dest.writeByte((byte) 0);
        } else {
            dest.writeByte((byte) 1);
            dest.writeInt(loadRequire);
        }
        if (unloadRequire == null) {
            dest.writeByte((byte) 0);
        } else {
            dest.writeByte((byte) 1);
            dest.writeInt(unloadRequire);
        }
        dest.writeInt(arrivalTime);
        dest.writeString(lostPromise);
        dest.writeString(performanceBond);
        dest.writeString(overduePromise);
        dest.writeString(otherPromise);
        dest.writeString(sendGoodsUnit);
        dest.writeString(sendPeople);
        dest.writeString(sendPhone);
        dest.writeString(receiveGoodsUnit);
        dest.writeString(receptionPeople);
        dest.writeString(receptionPhone);
        dest.writeString(payType);
        dest.writeString(receiptAccountRequire);
        dest.writeString(invoice);
        dest.writeString(tariff);
        dest.writeString(otherPaymentRequire);
        dest.writeString(quoteInvoiceInfoId);
        dest.writeString(quoteshCompanyName);
        dest.writeString(quoteCreditCode);
        dest.writeString(quoteAddress);
        dest.writeString(quotePhone);
        dest.writeString(quoteBank);
        dest.writeString(quoteBankAccount);
        dest.writeString(quoteBankNumber);
        if (createTime == null) {
            dest.writeByte((byte) 0);
        } else {
            dest.writeByte((byte) 1);
            dest.writeLong(createTime);
        }
        if (paymentEndTime == null) {
            dest.writeByte((byte) 0);
        } else {
            dest.writeByte((byte) 1);
            dest.writeLong(paymentEndTime);
        }
        if (systemTime == null) {
            dest.writeByte((byte) 0);
        } else {
            dest.writeByte((byte) 1);
            dest.writeLong(systemTime);
        }
        dest.writeString(orderNo);
        dest.writeString(mMessagePrice);
        dest.writeString(messageSerialNumber);
        if (messagePayTime == null) {
            dest.writeByte((byte) 0);
        } else {
            dest.writeByte((byte) 1);
            dest.writeLong(messagePayTime);
        }
        dest.writeString(messageCharge);
        dest.writeString(messagePayWay);
        dest.writeString(freightPrice);
        dest.writeString(freightSerialNumber);
        if (freightPayTime == null) {
            dest.writeByte((byte) 0);
        } else {
            dest.writeByte((byte) 1);
            dest.writeLong(freightPayTime);
        }
        dest.writeString(freightCharge);
        dest.writeString(freightPayWay);
        if (status == null) {
            dest.writeByte((byte) 0);
        } else {
            dest.writeByte((byte) 1);
            dest.writeInt(status);
        }
        if (startTime == null) {
            dest.writeByte((byte) 0);
        } else {
            dest.writeByte((byte) 1);
            dest.writeLong(startTime);
        }
        if (transitTime == null) {
            dest.writeByte((byte) 0);
        } else {
            dest.writeByte((byte) 1);
            dest.writeLong(transitTime);
        }
        dest.writeString(departureImg);
        if (completeTime == null) {
            dest.writeByte((byte) 0);
        } else {
            dest.writeByte((byte) 1);
            dest.writeLong(completeTime);
        }
        dest.writeString(receiveImg);
        dest.writeString(driverUserNo);
        dest.writeString(userName);
        dest.writeString(telPhone);
        dest.writeString(carAge);
        dest.writeString(driverAge);
        dest.writeString(carNumber);
        dest.writeString(carTypeName);
        dest.writeString(carLenName);
        dest.writeString(carWeight);
        dest.writeString(heightHurdle);
        dest.writeString(functionNos);
        dest.writeString(messagePrice);
        dest.writeString(allFreight);
        dest.writeFloat(latitude);
        dest.writeFloat(longitude);
        if (shipmentTime == null) {
            dest.writeByte((byte) 0);
        } else {
            dest.writeByte((byte) 1);
            dest.writeLong(shipmentTime);
        }
        if (shipmentEndTime == null) {
            dest.writeByte((byte) 0);
        } else {
            dest.writeByte((byte) 1);
            dest.writeLong(shipmentEndTime);
        }
        dest.writeString(goodsOwnerPhone);
        dest.writeString(provinceName);
        dest.writeString(cityName);
        dest.writeString(districtName);
        dest.writeString(detailAddress);
        dest.writeString(destCityName);
        dest.writeString(destDistrictName);
        dest.writeString(logo);
        dest.writeString(driverHeadImg);
        dest.writeString(sourceUserNo);
        dest.writeString(goodsOwnerImAccount);
        dest.writeString(driverOwnerImAccount);
        dest.writeInt(startPointTime);
        dest.writeInt(endPointTime);
        dest.writeString(freightType);
        if (transportType == null) {
            dest.writeByte((byte) 0);
        } else {
            dest.writeByte((byte) 1);
            dest.writeInt(transportType);
        }
        if (isOnlinePayment == null) {
            dest.writeByte((byte) 0);
        } else {
            dest.writeByte((byte) 1);
            dest.writeInt(isOnlinePayment);
        }
        dest.writeString(offlineImg);
        dest.writeString(secondGoodsTypeName);
        if (quoteOfferType == null) {
            dest.writeByte((byte) 0);
        } else {
            dest.writeByte((byte) 1);
            dest.writeInt(quoteOfferType);
        }
        if (inTime == null) {
            dest.writeByte((byte) 0);
        } else {
            dest.writeByte((byte) 1);
            dest.writeLong(inTime);
        }
        dest.writeString(quoteCompanyName);
        dest.writeString(quoteTeamName);
        dest.writeString(contrcts);
        dest.writeString(contrctsNumber);
        dest.writeString(note);
        dest.writeTypedList(addField);
        dest.writeString(messageOrderNo);
    }
}
